<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jstl/core_rt" prefix="c" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<!DOCTYPE HTML>
<html>
  <head>
    <base href="<%=basePath%>">
	<meta name="viewport" content="width=device-width, initial-scale=1">
	<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
	<title>法律产品详情</title>
	<link rel="stylesheet" type="text/css" href="css/normalize.css">
	<link rel="stylesheet" type="text/css" href="css/bootstrap.min.css">
	<link rel="stylesheet" type="text/css" href="css/my-style.css">
	<!--[if lt IE 9]> 
		<script src="js/html5shiv.min.js"></script> 
	<![endif]-->
</head>
<body>
	<!-- 导航栏 -->
	<header>
		<nav class="navbar navbar-inverse">
			<div class="container">
				<div class="navbar-header">
					<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar-collapse-1" aria-expanded="false">
		        <span class="sr-only">Toggle navigation</span>
		        <span class="icon-bar"></span>
		        <span class="icon-bar"></span>
		        <span class="icon-bar"></span>
		      </button>
		      <a class="navbar-brand" href="index.html">
		        <img alt="LOGO" src="img/50x30.png">
		      </a>
				</div>
				<div class="collapse navbar-collapse" id="navbar-collapse-1">
					<ul class="nav navbar-nav navbar-left">
						 <li><a href="index/home">首页</a></li>
				          <li><a href="lawyer/list">法律人</a></li>
				          <li class="cur"><a href="contract/list">法律产品</a></li>
				         <li><a href="knowledge/index">法律知识</a></li>
				          <li><a href="javascript:;">招聘</a></li>
					</ul>

					<ul class="nav navbar-nav navbar-right">
						  <li><a class="add-btn" href="index/join">法律人入驻<span class="caret"></span></a></li>
				          <c:if test="${sessionScope.user == null}">
								  <li><a href="user/login">登录</a></li>
	         					 <li><a href="user/register">注册</a></li>
						</c:if>
						<c:if test="${sessionScope.user != null}">
									 <li>
											<c:if test="${sessionScope.user.type  == 0}">
											<a href="user/person">${sessionScope.user.username}</a>
											</c:if>
											<c:if test="${sessionScope.user.type  == 1}">
											<a href="lawyer/person">${sessionScope.user.username}</a>
											</c:if>
											<c:if test="${sessionScope.user.type  == 2}">
											<a href="lawyer/person">${sessionScope.user.username}</a>
											</c:if>
								    </li>
	         					 <li><a href="user/logout">退出</a></li>
						</c:if>
					</ul>
				</div>
			</div>
		</nav>
	</header>

	
	<section>
		<div class="container">
			<div class="row">
				<h1>${contracts.title}</h1>
				<div class="pro-title">
					<p class="icon icon-eye">${contracts.readnum}人阅读过</p>
					<p class="icon icon-inbox"><a href="http://localhost:8080/${contracts.fileUrl}" download="${contracts.fileUrl}">点击下载</a></p>
					<p class="icon icon-clock">更新时间:<fmt:formatDate value="${contracts.time}" pattern="yyyy-MM-dd hh:mm:ss"/></p>
				</div>
			</div>
			<div class="row">
				<div class="col-md-9 col-sm-8 col-xs-12 clear-padding">
					<div class="pro-detail-box" style="height: 1200px">
							<iframe id="iframe" class="iframe" src="http://localhost:8080/${contracts.htmlUrl}" scrolling="yes" frameborder="no" width="100%" height="100%"></iframe>
					</div>
				</div>
				<%-- <div class="col-md-9 col-sm-8 col-xs-12 clear-padding">
					<div class="pro-detail-box" style="height: 1000px;">
						<iframe src="localhost:8080/${contracts.fileUrl}" scrolling="yes"  width="100%"></iframe>
					</div>
				</div> --%>
				<div class="col-md-3 col-sm-4 col-xs-12">
					<div class="col-md-12 text-center hidden-xs clear-padding">
						<img src="img/260x200.png" alt="">
					</div>
					<div class="col-md-12 col-sm-12 col-xs-12 clear-padding center-block">
						<div class="sidebar-box">
							<form action="" method="post">
								<h3>合同起稿</h3>
								<hr class="hr"/>
								<div class="form-group">
							    <label class="text-muted" for="sidebar-box-select1">合同类型</label>
							    <select class="form-control" id="sidebar-box-select1">
										<option>请选择合同类型</option>
										<option>类型1</option>
										<option>类型2</option>
									</select>
							  </div>
								<p>服务费用<b>0.0元</b></p>
								<div class="form-group">
									<label class="text-muted" for="sidebar-box-textarea1">合同描述</label>
									<textarea class="form-control" rows="4" placeholder="请填写您的合同描述" id="sidebar-box-textarea1"></textarea>
								</div>
								<div class="form-group">
									<label class="text-muted" for="sidebar-box-tel1">手机号</label>
									<input class="form-control" type="text" placeholder="请填写您的手机号" id="sidebar-box-tel1" name="">
								</div>
								<div class="form-group">
									<label class="text-muted" for="sidebar-box-email1">电子邮箱</label>
									<input class="form-control" type="text" placeholder="请填写您的电子邮箱" id="sidebar-box-email1" name="">
								</div>
								<button type="button" class="btn btn-primary btn-block">完成提交</button>
							</form>
						</div>
					</div>
					<div class="col-md-12 col-sm-12 col-xs-12 clear-padding center-block">
						<div class="sidebar-box">
							<form action="" method="post">
								<h3>合同审议</h3>
								<hr class="hr"/>
								<div class="form-group">
							    <label class="text-muted" for="sidebar-box-select2">合同类型</label>
							    <select class="form-control" id="sidebar-box-select2">
										<option>请选择合同类型</option>
										<option>类型1</option>
										<option>类型2</option>
									</select>
							  </div>
							  <div class="form-group">
							    <input type="file">
							    <p class="help-block" style="font-size:.7em;">(格式为jpg,png,word,ppt,pdf大小不超过3M)</p>
							  </div>
								<p>服务费用<b>0.0元</b></p>
								<div class="form-group">
									<label class="text-muted" for="sidebar-box-textarea2">合同描述</label>
									<textarea class="form-control" rows="4" placeholder="请填写您的合同描述" id="sidebar-box-textarea2"></textarea>
								</div>
								<div class="form-group">
									<label class="text-muted" for="sidebar-box-tel2">手机号</label>
									<input class="form-control" type="text" placeholder="请填写您的手机号" id="sidebar-box-tel2" name="">
								</div>
								<div class="form-group">
									<label class="text-muted" for="sidebar-box-email2">电子邮箱</label>
									<input class="form-control" type="text" placeholder="请填写您的电子邮箱" id="sidebar-box-email2" name="">
								</div>
								<button type="button" class="btn btn-primary btn-block">完成提交</button>
							</form>
						</div>
					</div>
				</div>
			</div>
		</div>
	</section>

	<script type="text/javascript" src="js/jquery.min.js"></script>
	<script type="text/javascript" src="js/bootstrap.min.js"></script>
</body>
</html>